const int PIR_Pin = 2;
const int RELAY_Pin = 3;

void setup() {
  // put your setup code here, to run once:
  pinMode(PIR_Pin, INPUT);
  pinMode(RELAY_Pin, OUTPUT);
  Serial.begin(9600);
}

void loop() {
  // put your main code here, to run repeatedly:
  
  while (!digitalRead(PIR_Pin)) {}
  
  digitalWrite(RELAY_Pin, HIGH);
  delay(1000);
  digitalWrite(RELAY_Pin, LOW);
  
//delay(1000);
}
